<table style="width: 100%;" cellpadding="4" cellspacing="0">
<tr>
    <td class="border2">
        
        {if $bInvited}
        	{str_replace text="`you_have_just_invited_suser_to_come`" sUser="`$sUser`" }
        	<ul>
        	<li><a href="{url link='public.user' name=$sUser"}">{language text="return_to_users_profile"}</a></li>
        	<li><a href="{url link='public.groups.mygroups'}">{language text="view_your_groups"}</a></li>
        	<li><a href="{url link='public.groups.invite' id=$nGroupId}">{language text="invite_more_to_this_group"}</a></li>
        	</ul>
        {else}
        	{if not $bErrors}
        	<div style="font-size:10pt;" class="color">
        	    <b>{language text="group_invite_951"} &gt;&gt;</b>
        	</div>
        	<br /><br />
        	<div style="font-size:10pt;padding:5px;">
        	
        	    <form method="post" action="{url link='public.groups.invitetogroup'}">
        	        <input type="hidden" name="invuser" value="{$sUser}" />
        			{str_replace text="`please_select_a_group_you_want_to_a`" sUser="`$sUser`" }:
        			<div style="padding:5px;"><br /><br />
        	            <b>{language text="select_group"}:</b>
        	            <select name="group" style="width:150px;">
        	            {foreach from=$aGroups item=aItem}
        	            <option value="{$aItem.id}">{$aItem.title}</option>
        	            {/foreach}
        	            </select>
        	            <br /><br />
        	            <input type="submit" value="{language text="invite_to_group"}" style="cursor:pointer;" />
        	            <input type="button" value=" {language text="cancel"} " onclick="javascript:window.location.href='{url link='public.user' name=$sUser}';" style="cursor:pointer;" />
        			</div>
        		</form>
        	</div>
        	{else}
        		{if $bNoUser}
        			{language text="error_you_did_not_select_a_user"}
        		{/if}
        		
        		{if $bSelf}
        			{language text="error_sorry_you_cant_add_yourself"}
        		{/if}
        		
        		{if $bIsMember}
        			{language text="error_sorry_this_user_is_already_a"}
        			<ul><li><a href="{url link='public.user' name=$sUser"}>{language text="go_to_profile"}</a></li></ul>
        		{/if}
        		
        		{if $bNoGroups}
        			{language text="error_sorry_you_dont_have_any_group"} <br />
        			{language text="you_need_to_create_a_group_first_th"}
        			<ul>
        			<li><a href="{url link='public.groups.edit}">{language text="create_a_group_now"}</a></li>
        			</ul>
        		{/if}
        	{/if}		
        {/if}
    </td>
</tr>
</table>